package com.dyh.quickdemo.demos.lbdFactoryBean;

import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import java.util.function.Function;

/*
@Author=Joey Wheeler
@Date=2021/1/11 14:16
*/
@Configuration
@Slf4j
public class FunctionBeanConfig {

    @Bean
    Function XXservice$funEnhance(){
        return FunctionEnhancer
                .with("XXservice$funEnhance",(Function<String,String>) XXservice::fun)
                .logStartEnd()
                .hideException()
                .regist();
        //.build();
    }

}
